package main
import(
	"fmt"
)
//斐波那契
func main(){
	slice := make([]int,0)
	slice = append(slice,1)
	slice = append(slice,1)
	slice = fibonacci(20,slice)
	fmt.Println(slice)
}

func fibonacci(n int,slice []int) []int{
	for i := 2; i < n ; i++{
		slice = append(slice,slice[i-1]+slice[i-2])
	}
	return slice
}

func test(slice *[]int){
	*slice = append(*slice,1)
}